<template>
  <div class="common-layout">
    <el-container>
      <el-aside width="160px">
        <SideNav></SideNav>
      </el-aside>
      <el-main class="el-main">
        <div>
          <router-view v-slot="{ Component }">
            <keep-alive>
              <component :is="Component"/>
            </keep-alive>
          </router-view>
        </div>
      </el-main>
    </el-container>
  </div>
</template>

<script setup>
import SideNav from '../components/sider-nav.vue'
</script>

<style scoped lang='scss'>
.el-main{
  padding: 0 20px;
}
</style>
